<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>     
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>车位列表</title>
<jsp:include page="/layout/_css.jsp"/>
</head>
<body>
	<body class="gray-bg">
		<div class="wrapper wrapper-content animated fadeInRight">
			<div class="row">
				<div class="col-sm-12">
					  <div class="ibox float-e-margins">
					  	 <div class="ibox-title">
					  	 	<h5>车位列表</h5>
					  	 </div>
					  	 <div class="ibox-content">
			    			 <table id="table"></table>
					  	 </div>
					  </div>
				</div>
			</div>	
		</div>
	</body>
</body>
<jsp:include page="/layout/_script.jsp"></jsp:include>
<script src="https://cdn.bootcss.com/bootstrap-table/1.12.1/bootstrap-table.js"></script>
<script src="https://cdn.bootcss.com/bootstrap-table/1.12.1/locale/bootstrap-table-zh-CN.js"></script>
<script>
$('#table').bootstrapTable({
    url: '${ctx}/UserServlet/listAllCarBack',
    columns: [
    	{
    	checkbox:true
    	},{
        field: 'c_id',
        title: '车位号',
        sortable:true
    }, {
        field: 'c_order',
        title: '是否预订'
    },{
        field: '',
        title: ''
    },{
        field: '',
        title: ''
    },{
        field: '',
        title: ''
    },{
    	field: 'caozuo',
        title: '操作',
        formatter:function(v1){
        	return ['<span>请管理员及时更新车位列表</span>'].join('');
        },
    }],
    pagination:true,
    pageSize:10,
    pageList:[5,10,15],
    search:true,
    showColumns:true,
    clickToSelect:true,
    sidePagination:'server',
    rowStyle:function(v,index){
    	var classes = ['active', 'success', 'info', 'warning', 'danger'];
        return {}; 
    }
});
</script>
</html>